package cn.com.nes.mybatis.agent.crm.mapper;

import cn.com.nes.mybatis.agent.crm.entity.OpportunityAreaCode;
import cn.com.nes.site.service.crm.opportunity.bo.OpportunityAreaCodeBo;
import cn.com.nes.site.service.crm.opportunity.dto.OpportunityAreaCodeDTO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author yishuai
 */
public interface OpportunityAreaCodeMapper extends BaseMapper<OpportunityAreaCode> {

    void deleteByOpportunityUuid(@Param("bo") OpportunityAreaCodeBo opportunityAreaCodeBo);


    List<String> getOpportunityIdListByAreaCode(@Param("parentAreaCodeList") List<String> parentAreaCodeList,
            @Param("regionCodePrefix") String regionCodePrefix);


    List<OpportunityAreaCodeDTO> getOpportunityAreaCodeDtos(String opportunityUuid);


    /**
     * 查询商务项目设置的区划代码集
     * @param opportunityUuid   商务项目UUID
     * @return
     */
    List<String> getOpportunitySettingRegions(@Param("opportunityUuid") String opportunityUuid);

}




